﻿namespace jQube.Web
{
    using System.Web;
    using System.IO;

    internal class HttpResponseWrapper : IHttpResponse
    {
        public HttpResponseWrapper(HttpResponse httpResponse)
        {
            this.HttpResponse = httpResponse;
        }

        public HttpResponse HttpResponse { get; private set; }

        #region Miembros de IHttpResponse

        IHttpCachePolicy IHttpResponse.Cache
        {
            get { return new HttpCachePolicyWrapper(this.HttpResponse.Cache); }
        }

        string IHttpResponse.ContentType
        {
            get { return this.HttpResponse.ContentType; }
            set { this.HttpResponse.ContentType = value; }
        }

        Stream IHttpResponse.Filter
        {
            get { return this.HttpResponse.Filter; }
            set { this.HttpResponse.Filter = value; }
        }

        TextWriter IHttpResponse.Output
        {
            get { return this.HttpResponse.Output; }
        }

        void IHttpResponse.AddHeader(string name, string value)
        {
            this.HttpResponse.AddHeader(name, value);
        }

        void IHttpResponse.BinaryWrite(byte[] buffer)
        {
            this.HttpResponse.BinaryWrite(buffer);
        }

        void IHttpResponse.Clear()
        {
            this.HttpResponse.Clear();
        }

        void IHttpResponse.End()
        {
            this.HttpResponse.End();
        }

        void IHttpResponse.Flush()
        {
            this.HttpResponse.Flush();
        }

        void IHttpResponse.Write(string s)
        {
            this.HttpResponse.Write(s);
        }

        #endregion
    }
}
